package cc.comac.mom.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import cc.comac.mom.api.EquipOperatorService;
import cc.comac.mom.bean.EquipOperator;
import cc.comac.mom.util.ResultBean;

@RestController
@RequestMapping(value ="/EquipOperator")
public class EquipOperatorController {

	@Autowired
	private EquipOperatorService equipOperatorService;
	
	@RequestMapping(value = "/save",method = RequestMethod.POST)
	public ResultBean save(@RequestBody EquipOperator obj) {		
		return equipOperatorService.save(obj);		
	}
	
	@RequestMapping(value = "/saveBatch",method = RequestMethod.POST)
	public ResultBean saveBatch(@RequestBody List<EquipOperator> list) {		
		return equipOperatorService.saveBatch(list);		
	}
	
	@RequestMapping(value = "/deleteBatch",method = RequestMethod.POST)
	public ResultBean deleteBatch(@RequestBody List<EquipOperator> list) {		
		return equipOperatorService.deleteBatch(list);		
	}
	
	@RequestMapping(value = "/selectByCondition",method = RequestMethod.POST)
	public ResultBean selectByCondition(@RequestBody EquipOperator obj) {		
		return equipOperatorService.selectByCondition(obj);		
	}
}
